﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Data;
using Home.Haushalt.Lib.Element;

namespace Home.Haushalt.Lib.Test
{
    /// <summary>
    /// 
    /// </summary>
    public class TestBase
    {

        internal protected DataTable GetPostenTable(string fileName)
        {
            DataSet postenDS = new DataSet();
            postenDS.ReadXml(fileName);

            return postenDS.Tables[0];
        }

        internal protected DataTable GetDateTable(string fileName)
        {
            DataSet dateDS = new DataSet();
            if (fileName == null)
            {
                dateDS.OpenSchema(typeof(Date));
            }
            else
            {
                dateDS.ReadXml(fileName);
            }
            return dateDS.Tables[0]; ;
        }
    }
}
